import 'package:flutter_deer/generated/json/base/json_field.dart';
import 'package:flutter_deer/generated/json/socket_serializable_models.g.dart';

// 第一个类 MdcSetPrcNzlCmdBean
@JsonSerializable()
class MdcSetPrcNzlCmdBean {

  MdcSetPrcNzlCmdBean();

  // 生成工厂构造函数
  factory MdcSetPrcNzlCmdBean.fromJson(Map<String, dynamic> json) => $MdcSetPrcNzlCmdBeanFromJson(json);
  int cmdType = 0;
  int num = 0;
  List<PrcOil> items = [];

  // 生成 toJson 方法
  Map<String, dynamic> toJson() => $MdcSetPrcNzlCmdBeanToJson(this);

  @override
  String toString() {
    return 'MdcSetPrcNzlCmdBean{cmdType: $cmdType, num: $num, items: $items}';
  }
}

@JsonSerializable()
class PrcOil {
  PrcOil();

  factory PrcOil.fromJson(Map<String, dynamic> json) => $PrcOilFromJson(json);

  int nzl = 0;
  int prc = 0;

  Map<String, dynamic> toJson() => $PrcOilToJson(this);

  @override
  String toString() {
    return '{nzl: $nzl, prc: $prc}';
  }
}